/**
 * Sample React Native App
 * https://github.com/facebook/react-native
 * @flow
 */

import React, { Component } from 'react';
import {
    AppRegistry,
    StyleSheet,
    Text,
    View,
    Navigator
} from 'react-native';
import FirstView from './FirstView'
export default class NavDemo extends Component {
    render() {
        return (
            <Navigator
              initialRoute={{component:FirstView,
              params:{
                  title:"第一个视图",
                  haha:"哈哈",
                  hehe:"呵呵",
                  heihei:"嘿嘿"
              }}}
              renderScene={(route,navigator) =>
                  <route.component {...route.params} nav={navigator} />}
              configureScene={()=>
               Navigator.SceneConfigs.FloatFromRight}
            />
        );
    }
}

const styles = StyleSheet.create({
    container: {
        flex: 1,
        justifyContent: 'center',
        alignItems: 'center',
        backgroundColor: '#F5FCFF',
    },
    welcome: {
        fontSize: 20,
        textAlign: 'center',
        margin: 10,
    },
    instructions: {
        textAlign: 'center',
        color: '#333333',
        marginBottom: 5,
    },
});